﻿@model List<Dictionary<string, object>>  

<table width="100%" border="0" cellspacing="1" bgcolor="#d2d2d2" class="xq_table" style="font-size:12px">
    @{
        List<Dictionary<string, object>> ls = (List<Dictionary<string, object>>)Model;
        foreach (Dictionary<string, object> d in ls)
        {
        <tr>
            <td colspan="8" style="background:#E3EEEF;">
                <div class="la_name_b">
                    <h6>
                        贷款信息</h6>
                    <span>项目经理：@d["项目经理"] 电话：@d["联系电话"]</span></div>
            </td>
        </tr>
        <tr>
            <td width="12%" bgcolor="#FFFFFF">
                <b>客户名称：</b>
            </td>
            <td width="12%" bgcolor="#FFFFFF">
                @d["客户名称"]
            </td>
            <td width="12%" bgcolor="#FFFFFF">
               <b> 业务ID：</b>
            </td>
            <td width="12%" bgcolor="#FFFFFF">
                @d["业务ID"]
            </td>
            <td width="12%" bgcolor="#FFFFFF">
                <b>放款日期：</b>
            </td>
            <td width="16%" bgcolor="#FFFFFF">
                @d["放款日期"]
            </td>
            <td width="12%" bgcolor="#FFFFFF">
                <b>还款方式：</b>
            </td>
            <td bgcolor="#FFFFFF">
                @d["还款方式"]
            </td>
        </tr>
        <tr>
            <td bgcolor="#FFFFFF">
                <b>贷款金额：</b>
            </td>
            <td bgcolor="#FFFFFF">
                @d["贷款金额"]
            </td>
            <td bgcolor="#FFFFFF">
                <b>贷款期限：</b>
            </td>
            <td bgcolor="#FFFFFF">
                @d["贷款期限"]
            </td>
            <td bgcolor="#FFFFFF">
                <b>月利率：</b>
            </td>
            <td bgcolor="#FFFFFF">
                @d["月利率"]
            </td>
            <td bgcolor="#FFFFFF" colspan="2">
                <dd>
                    <input type="button" onclick="loadDetail(@d["业务ID"])" value="查看详情" />
                    <input type="button" onclick="CloseDetail(@d["业务ID"])" value="收起详情" />
                    </dd>
            </td>

        </tr>       
        <tr><td colspan="8">
        <div id="@("detailDt_" + d["业务ID"])" class="detailDt"></div>
        </td></tr>
        }
    }
</table>
<script type="text/javascript">
    function loadDetail(bid) {
        alert("001");
        //$(".detailDt").empty();
        alert("002");
        var htmlname = "detailDt_" + bid;
        $("#" + htmlname).load(
            "/Query/GetDetails",
            {
                bId: bid
            });
            alert("003");
        }

        function CloseDetail(bid) {
            var htmlname = "detailDt_" + bid;
            $("#" + htmlname).empty();
        }
</script>
